﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Avatar.Model;
using AvatarHelper;

public partial class HighLevelJobDetail : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            using (var _adc = DBHelper.GetDataContext())
            {
                if (Request.QueryString["ID"] != null)
                {
                    var _job = _adc.HighJob.FirstOrDefault(j => j.ID == Convert.ToInt32(Request.QueryString["id"].ToString()));
                    if (_job != null)
                    {
                        lbl_Title.Text = _job.Title;
                        lbl_Company.Text = _job.CompanyName;
                        lbl_PublishDate.Text = _job.PublishDate.ToShortDateString();
                        lbl_Content.Text = _job.Content;
                    }
                }
            }
        }
    }
}
